/*
 * Copyright 2002-2019 the original author or authors.
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *      https://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

package org.springframework.beans;

import org.springframework.lang.Nullable;

/**
 * Interface to be implemented by bean metadata elements
 * that carry a configuration source object.
 *
 * @author Juergen Hoeller
 * @since 2.0
 */

/**
 这个接口的主要目的是提供一个统一的方式来访问 bean 配置元素的源信息（configuration source）。
 在 Spring 容器处理 bean 定义时，能够追踪到这些定义来源于哪里，比如：XML 配置文件中的具体行号和文件名，Java 配置类中的具体方法和类名，注解配置的具体注解位置

 直接子接口
	 BeanDefinition - Bean 定义的核心接口
		 代表一个 bean 实例的定义信息
		 包含 bean 的类名、作用域、生命周期、依赖关系等元数据
	 PropertyValue - 属性值接口
		 表示 bean 属性的值配置
	 ConstructorArgumentValues.ValueHolder - 构造函数参数值持有者



 */
public interface BeanMetadataElement {

	/**
	 * Return the configuration source {@code Object} for this metadata element
	 * (may be {@code null}).
	 */
	@Nullable
	default Object getSource() {
		return null;
	}

}
